<template>
  <div class="about">
    <h1>This is an about page</h1>
    <div>
      <input type="text" v-model="fathermsg">
    <child-component :fathermsg = "fathermsg" ></child-component>

    </div>
    <div>{{msg}}</div>
    <msg-component @send="loadMsg">
      <template v-slot:solta="space">
        <div>父组件上的solt：{{space.soltmsg}}</div>
      </template>
    </msg-component>
    <h2>循环加方法</h2>
    <list-component></list-component>
  </div>
</template>
<script>
import ChildComponent from "@/components/ChildComponent";
import MsgComponent from '@/components/MsgComponent.vue';
import ListComponent from '@/components/ListComponent.vue';

export default {
  name: "AboutHome",
  data() {
    return {
      obj: {
        a: 3,
        b: 32,
      },
      fathermsg:"父组件",
      msg:"子组件"
    };
  },
  components: {
    ChildComponent,
    MsgComponent,
    ListComponent,
  },
  methods:{
    loadMsg(arg){
      this.msg = arg
    }
  },
  computed:{
    
  }
};
</script>